<!DOCTYPE html>



  


<html class="theme-next gemini use-motion" lang="en">
<head><meta name="generator" content="Hexo 3.9.0">
  <meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta name="theme-color" content="#222">









<meta http-equiv="Cache-Control" content="no-transform">
<meta http-equiv="Cache-Control" content="no-siteapp">
















  
  
  <link href="/lib/fancybox/source/jquery.fancybox.css?v=2.1.5" rel="stylesheet" type="text/css">







<link href="/lib/font-awesome/css/font-awesome.min.css?v=4.6.2" rel="stylesheet" type="text/css">

<link href="/css/main.css?v=5.1.4" rel="stylesheet" type="text/css">


  <link rel="apple-touch-icon" sizes="180x180" href="/images/apple-touch-icon-next.png?v=5.1.4">


  <link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-xm.ico?v=5.1.4">


  <link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-xm.ico?v=5.1.4">


  <link rel="mask-icon" href="/images/logo.svg?v=5.1.4" color="#222">





  <meta name="keywords" content="Hexo, NexT">










<meta name="description" content="走进java概述优点 用户量大  一次编写，到处运行  程序员只需要用JDK提供的接口，不必关心硬件如何如何   安全的内存管理机制  看过C++那丑陋的指针和引用就能明白这点   热点代码检测和运行时编译及优化  越跑越快   各种库">
<meta property="og:type" content="article">
<meta property="og:title" content="走进Java">
<meta property="og:url" content="http://yoursite.com/2020/05/09/走进Java/index.html">
<meta property="og:site_name" content="Ming">
<meta property="og:description" content="走进java概述优点 用户量大  一次编写，到处运行  程序员只需要用JDK提供的接口，不必关心硬件如何如何   安全的内存管理机制  看过C++那丑陋的指针和引用就能明白这点   热点代码检测和运行时编译及优化  越跑越快   各种库">
<meta property="og:locale" content="en">
<meta property="og:image" content="http://ww1.sinaimg.cn/large/005VT09Qly1gemk7hk8dtj316432dnf8.jpg">
<meta property="og:updated_time" content="2020-08-25T01:56:37.443Z">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="走进Java">
<meta name="twitter:description" content="走进java概述优点 用户量大  一次编写，到处运行  程序员只需要用JDK提供的接口，不必关心硬件如何如何   安全的内存管理机制  看过C++那丑陋的指针和引用就能明白这点   热点代码检测和运行时编译及优化  越跑越快   各种库">
<meta name="twitter:image" content="http://ww1.sinaimg.cn/large/005VT09Qly1gemk7hk8dtj316432dnf8.jpg">



<script type="text/javascript" id="hexo.configurations">
  var NexT = window.NexT || {};
  var CONFIG = {
    root: '/',
    scheme: 'Gemini',
    version: '5.1.4',
    sidebar: {"position":"left","display":"post","offset":12,"b2t":false,"scrollpercent":false,"onmobile":false},
    fancybox: true,
    tabs: true,
    motion: {"enable":true,"async":false,"transition":{"post_block":"fadeIn","post_header":"slideDownIn","post_body":"slideDownIn","coll_header":"slideLeftIn","sidebar":"slideUpIn"}},
    duoshuo: {
      userId: '0',
      author: 'Author'
    },
    algolia: {
      applicationID: '',
      apiKey: '',
      indexName: '',
      hits: {"per_page":10},
      labels: {"input_placeholder":"Search for Posts","hits_empty":"We didn't find any results for the search: ${query}","hits_stats":"${hits} results found in ${time} ms"}
    }
  };
</script>



  <link rel="canonical" href="http://yoursite.com/2020/05/09/走进Java/">





  <title>走进Java | Ming</title>
  





  <script type="text/javascript">
    var _hmt = _hmt || [];
    (function() {
      var hm = document.createElement("script");
      hm.src = "https://hm.baidu.com/hm.js?2ff12830577cde1e94dd80bdcf083398";
      var s = document.getElementsByTagName("script")[0];
      s.parentNode.insertBefore(hm, s);
    })();
  </script>




</head>

<body itemscope itemtype="http://schema.org/WebPage" lang="en">

  
  
    
  

  <div class="container sidebar-position-left page-post-detail">
    <div class="headband"></div>

    <header id="header" class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-brand-wrapper">
  <div class="site-meta ">
    

    <div class="custom-logo-site-title">
      <a href="/" class="brand" rel="start">
        <span class="logo-line-before"><i></i></span>
        <span class="site-title">Ming</span>
        <span class="logo-line-after"><i></i></span>
      </a>
    </div>
      
        <p class="site-subtitle"></p>
      
  </div>

  <div class="site-nav-toggle">
    <button>
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
    </button>
  </div>
</div>

<nav class="site-nav">
  

  
    <ul id="menu" class="menu">
      
        
        <li class="menu-item menu-item-home">
          <a href="/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-home"></i> <br>
            
            Home
          </a>
        </li>
      
        
        <li class="menu-item menu-item-about">
          <a href="/about/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-user"></i> <br>
            
            About
          </a>
        </li>
      
        
        <li class="menu-item menu-item-categories">
          <a href="/categories/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-th"></i> <br>
            
            Categories
          </a>
        </li>
      
        
        <li class="menu-item menu-item-archives">
          <a href="/archives/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-archive"></i> <br>
            
            Archives
          </a>
        </li>
      
        
        <li class="menu-item menu-item-commonweal">
          <a href="/404/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-heartbeat"></i> <br>
            
            Commonweal 404
          </a>
        </li>
      

      
        <li class="menu-item menu-item-search">
          
            <a href="javascript:;" class="popup-trigger">
          
            
              <i class="menu-item-icon fa fa-search fa-fw"></i> <br>
            
            Search
          </a>
        </li>
      
    </ul>
  

  
    <div class="site-search">
      
  <div class="popup search-popup local-search-popup">
  <div class="local-search-header clearfix">
    <span class="search-icon">
      <i class="fa fa-search"></i>
    </span>
    <span class="popup-btn-close">
      <i class="fa fa-times-circle"></i>
    </span>
    <div class="local-search-input-wrapper">
      <input autocomplete="off" placeholder="Searching..." spellcheck="false" type="text" id="local-search-input">
    </div>
  </div>
  <div id="local-search-result"></div>
</div>



    </div>
  
</nav>



 </div>
    </header>

    <main id="main" class="main">
      <div class="main-inner">
        <div class="content-wrap">
          <div id="content" class="content">
            

  <div id="posts" class="posts-expand">
    

  

  
  
  

  <article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
  
  
  
  <div class="post-block">
    <link itemprop="mainEntityOfPage" href="http://yoursite.com/2020/05/09/走进Java/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Ming">
      <meta itemprop="description" content>
      <meta itemprop="image" content="/images/arina.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Ming">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">走进Java</h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">Posted on</span>
              
              <time title="Post created" itemprop="dateCreated datePublished" datetime="2020-05-09T22:17:16+08:00">
                2020-05-09
              </time>
            

            

            
          </span>

          
            <span class="post-category">
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">In</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/categories/JVM/" itemprop="url" rel="index">
                    <span itemprop="name">JVM</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
          

          
          

          

          
            <div class="post-wordcount">
              
                
                <span class="post-meta-item-icon">
                  <i class="fa fa-file-word-o"></i>
                </span>
                
                  <span class="post-meta-item-text">Words count in article&#58;</span>
                
                <span title="Words count in article">
                  787
                </span>
              

              
                <span class="post-meta-divider">|</span>
              

              
                <span class="post-meta-item-icon">
                  <i class="fa fa-clock-o"></i>
                </span>
                
                  <span class="post-meta-item-text">Reading time &asymp;</span>
                
                <span title="Reading time">
                  3
                </span>
              
            </div>
          

          

        </div>
      </header>
    

    
    
    
    <div class="post-body" itemprop="articleBody">

      
      

      
        <h1 id="走进java"><a href="#走进java" class="headerlink" title="走进java"></a>走进java</h1><h2 id="概述"><a href="#概述" class="headerlink" title="概述"></a>概述</h2><h3 id="优点"><a href="#优点" class="headerlink" title="优点"></a>优点</h3><ul>
<li><p>用户量大</p>
</li>
<li><p>一次编写，到处运行</p>
<ul>
<li>程序员只需要用JDK提供的接口，不必关心硬件如何如何</li>
</ul>
</li>
<li><p>安全的内存管理机制</p>
<ul>
<li>看过C++那丑陋的指针和引用就能明白这点</li>
</ul>
</li>
<li><p>热点代码检测和运行时编译及优化</p>
<ul>
<li>越跑越快</li>
</ul>
</li>
<li><p>各种库</p>
</li>
</ul>
<a id="more"></a>

<h2 id="java技术体系"><a href="#java技术体系" class="headerlink" title="java技术体系"></a>java技术体系</h2><h3 id="组成"><a href="#组成" class="headerlink" title="组成"></a>组成</h3><ul>
<li><p>根据功能划分</p>
<ul>
<li><p>java语言</p>
</li>
<li><p>各种硬件平台上的JVM</p>
</li>
<li><p>Class文件</p>
</li>
<li><p>第三方java类库</p>
<ul>
<li>商业机构</li>
<li>开源社区</li>
</ul>
</li>
<li><p>java API 类库</p>
</li>
</ul>
</li>
<li><p>根据服务领域划分</p>
<ul>
<li><p>Java Card</p>
<ul>
<li>java程序运行在小内存设备的平台</li>
</ul>
</li>
<li><p>Java ME</p>
<ul>
<li><p>含义</p>
<ul>
<li>micro edition</li>
</ul>
</li>
<li><p>特点</p>
<ul>
<li>对java API有所精简</li>
<li>加入了对移动终端的支持</li>
</ul>
</li>
<li><p>曾用名</p>
<ul>
<li>J2ME</li>
</ul>
</li>
</ul>
</li>
<li><p>Java SE</p>
<ul>
<li><p>含义</p>
<ul>
<li>standard edition</li>
</ul>
</li>
<li><p>特点</p>
<ul>
<li>支持面向桌面级应用的java平台</li>
<li>完整的java核心API</li>
</ul>
</li>
<li><p>曾用名</p>
<ul>
<li>J2SE</li>
</ul>
</li>
</ul>
</li>
<li><p>Java EE</p>
<ul>
<li><p>含义</p>
<ul>
<li>enterprise edition</li>
</ul>
</li>
<li><p>特点</p>
<ul>
<li>支持使用多层架构的企业应用</li>
<li>对Java SE API做了扩充</li>
</ul>
</li>
<li><p>曾用名</p>
<ul>
<li>J2EE</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
<h3 id="JDK-VS-JRE"><a href="#JDK-VS-JRE" class="headerlink" title="JDK VS JRE"></a>JDK VS JRE</h3><ul>
<li><p>JDK</p>
<ul>
<li><p>Java Development Kit</p>
<ul>
<li>开发java程序</li>
</ul>
</li>
</ul>
</li>
<li><p>JRE</p>
<ul>
<li><p>Java Runtime Environment</p>
<ul>
<li>运行java程序</li>
</ul>
</li>
</ul>
</li>
</ul>
<h2 id="java发展史"><a href="#java发展史" class="headerlink" title="java发展史"></a>java发展史</h2><h3 id="James-Gosling"><a href="#James-Gosling" class="headerlink" title="James Gosling"></a>James Gosling</h3><h3 id="Oak"><a href="#Oak" class="headerlink" title="Oak"></a>Oak</h3><h3 id="JDK-1-0"><a href="#JDK-1-0" class="headerlink" title="JDK 1.0"></a>JDK 1.0</h3><ul>
<li><p>Write Once，Run anywhere</p>
</li>
<li><p>JVM</p>
</li>
<li><p>Applet</p>
<ul>
<li>可以包含在HTML里的一个小程序</li>
</ul>
</li>
<li><p>AWT</p>
<ul>
<li>类似swing、javafx这种吧，idk</li>
</ul>
</li>
</ul>
<h3 id="JDK-1-1"><a href="#JDK-1-1" class="headerlink" title="JDK 1.1"></a>JDK 1.1</h3><ul>
<li><p>JDBC</p>
<ul>
<li>程序员用java访问数据库只需要关心JDBC提供的接口，实现类由具体的数据库驱动提供</li>
</ul>
</li>
<li><p>JavaBeans</p>
</li>
<li><p>RMI</p>
<ul>
<li>Remote Method Invocation</li>
</ul>
</li>
<li><p>Inner class</p>
<ul>
<li>没用过，感觉不常用，好奇怪</li>
</ul>
</li>
<li><p>Reflection</p>
</li>
</ul>
<h3 id="JDK-1-1发布了9个版本"><a href="#JDK-1-1发布了9个版本" class="headerlink" title="JDK 1.1发布了9个版本"></a>JDK 1.1发布了9个版本</h3><h3 id="JDK-1-2"><a href="#JDK-1-2" class="headerlink" title="JDK 1.2"></a>JDK 1.2</h3><ul>
<li><p>java技术体系被拆分</p>
<ul>
<li><p>J2SE</p>
<ul>
<li><p>Java 2 Platform，Standard Edition</p>
<ul>
<li>面向桌面级应用</li>
</ul>
</li>
</ul>
</li>
<li><p>J2EE</p>
<ul>
<li><p>Java 2 Platform，Enterprise Edition</p>
<ul>
<li>面向企业级开发</li>
</ul>
</li>
</ul>
</li>
<li><p>J2ME</p>
<ul>
<li>Java 2 Platform，Micro Edition</li>
</ul>
</li>
</ul>
</li>
<li><p>strictfp关键字</p>
</li>
<li><p>Collections类</p>
</li>
</ul>
<h3 id="HotSpot虚拟机发布"><a href="#HotSpot虚拟机发布" class="headerlink" title="HotSpot虚拟机发布"></a>HotSpot虚拟机发布</h3><ul>
<li>后来成了JDK的默认虚拟机</li>
</ul>
<h3 id="JDK-1-3"><a href="#JDK-1-3" class="headerlink" title="JDK 1.3"></a>JDK 1.3</h3><ul>
<li>一些闻所未闻看不懂的新特性</li>
</ul>
<h3 id="JDK-1-4"><a href="#JDK-1-4" class="headerlink" title="JDK 1.4"></a>JDK 1.4</h3><ul>
<li><p>走向成熟的版本</p>
</li>
<li><p>正则表达式</p>
</li>
<li><p>异常链</p>
<ul>
<li>你抛我，我抛他，形成永动</li>
</ul>
</li>
<li><p>NIO</p>
</li>
<li><p>日志类</p>
</li>
<li><p>XML解析器</p>
</li>
</ul>
<h3 id="NET-Framework发布"><a href="#NET-Framework发布" class="headerlink" title=".NET Framework发布"></a>.NET Framework发布</h3><ul>
<li>强势竞争</li>
</ul>
<h3 id="JDK-1-5"><a href="#JDK-1-5" class="headerlink" title="JDK 1.5"></a>JDK 1.5</h3><ul>
<li><p>自动装箱</p>
<ul>
<li>把基本类型转换为包装类型</li>
</ul>
</li>
<li><p>泛型</p>
</li>
<li><p>动态注解</p>
</li>
<li><p>枚举</p>
</li>
<li><p>可变长参数</p>
</li>
<li><p>foreach</p>
</li>
<li><p>改进了JMM</p>
<ul>
<li>Java Memory Model</li>
</ul>
</li>
</ul>
<h3 id="JDK-1-6"><a href="#JDK-1-6" class="headerlink" title="JDK 1.6"></a>JDK 1.6</h3><ul>
<li><p>全新的命名方式</p>
</li>
<li><p>对虚拟机内部做了很多改进</p>
<ul>
<li>锁与同步</li>
<li>垃圾收集</li>
<li>类加载</li>
</ul>
</li>
</ul>
<h3 id="Sun被Oracle收购"><a href="#Sun被Oracle收购" class="headerlink" title="Sun被Oracle收购"></a>Sun被Oracle收购</h3><h2 id="展望Java的未来"><a href="#展望Java的未来" class="headerlink" title="展望Java的未来"></a>展望Java的未来</h2><h3 id="模块化"><a href="#模块化" class="headerlink" title="模块化"></a>模块化</h3><h3 id="混合语言"><a href="#混合语言" class="headerlink" title="混合语言"></a>混合语言</h3><ul>
<li>催生了许多新语言</li>
<li>许多老古董也有了jvm特供版</li>
</ul>
<h3 id="多核并行"><a href="#多核并行" class="headerlink" title="多核并行"></a>多核并行</h3><ul>
<li>Fork/Join</li>
</ul>
<h3 id="丰富语法"><a href="#丰富语法" class="headerlink" title="丰富语法"></a>丰富语法</h3><ul>
<li>比如函数式编程</li>
</ul>
<h3 id="64位虚拟机"><a href="#64位虚拟机" class="headerlink" title="64位虚拟机"></a>64位虚拟机</h3><ul>
<li>现在可能已经过渡完成了，毕竟我看的是9年前出版的书，那时候java8还没发布呢</li>
</ul>
<h2 id="自己编译JDK"><a href="#自己编译JDK" class="headerlink" title="自己编译JDK"></a>自己编译JDK</h2><h3 id="获取JDK原码"><a href="#获取JDK原码" class="headerlink" title="获取JDK原码"></a>获取JDK原码</h3><ul>
<li>OPENJDK之类的</li>
</ul>
<h3 id="构建编译环境"><a href="#构建编译环境" class="headerlink" title="构建编译环境"></a>构建编译环境</h3><ul>
<li>说出来你可能不信，JDK使用C++编译器编译的（部分），所以要选个IDE的话，VS是不错的选择</li>
<li>当然很多代码还是用java写的，所以还需要一个已经编译好的JDKhhh</li>
</ul>
<h3 id="OPEN-JDK也不是100-开源的，有些依赖项是闭包的，得手动下载那些个依赖项才好JDK-plug"><a href="#OPEN-JDK也不是100-开源的，有些依赖项是闭包的，得手动下载那些个依赖项才好JDK-plug" class="headerlink" title="OPEN JDK也不是100%开源的，有些依赖项是闭包的，得手动下载那些个依赖项才好JDK plug"></a>OPEN JDK也不是100%开源的，有些依赖项是闭包的，得手动下载那些个依赖项才好JDK plug</h3><h3 id="开始编译"><a href="#开始编译" class="headerlink" title="开始编译"></a>开始编译</h3><ul>
<li><p>细节一大堆</p>
<ul>
<li>tlds<img referrerpolicy="no-referrer" src="http://ww1.sinaimg.cn/large/005VT09Qly1gemk7hk8dtj316432dnf8.jpg">
</li>
</ul>
</li>
</ul>

      
    </div>
    
    
    

    

    
      <div>
        <div style="padding: 10px 0; margin: 20px auto; width: 90%; text-align: center;">
  <div>赠人玫瑰，手有余香</div>
  <button id="rewardButton" disable="enable" onclick="var qr = document.getElementById('QR'); if (qr.style.display === 'none') {qr.style.display='block';} else {qr.style.display='none'}">
    <span>Donate</span>
  </button>
  <div id="QR" style="display: none;">

    
      <div id="wechat" style="display: inline-block">
        <img id="wechat_qr" src="/images/wechatpay.png" alt="Ming WeChat Pay">
        <p>WeChat Pay</p>
      </div>
    

    
      <div id="alipay" style="display: inline-block">
        <img id="alipay_qr" src="/images/alipay.jpg" alt="Ming Alipay">
        <p>Alipay</p>
      </div>
    

    

  </div>
</div>

      </div>
    

    

    <footer class="post-footer">
      

      
      
      

      
        <div class="post-nav">
          <div class="post-nav-next post-nav-item">
            
              <a href="/2020/05/09/plan/" rel="next" title="plan">
                <i class="fa fa-chevron-left"></i> plan
              </a>
            
          </div>

          <span class="post-nav-divider"></span>

          <div class="post-nav-prev post-nav-item">
            
              <a href="/2020/05/09/http/" rel="prev" title="http">
                http <i class="fa fa-chevron-right"></i>
              </a>
            
          </div>
        </div>
      

      
      
    </footer>
  </div>
  
  
  
  </article>



    <div class="post-spread">
      
    </div>
  </div>


          </div>
          


          

  



        </div>
        
          
  
  <div class="sidebar-toggle">
    <div class="sidebar-toggle-line-wrap">
      <span class="sidebar-toggle-line sidebar-toggle-line-first"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-middle"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-last"></span>
    </div>
  </div>

  <aside id="sidebar" class="sidebar">
    
    <div class="sidebar-inner">

      

      
        <ul class="sidebar-nav motion-element">
          <li class="sidebar-nav-toc sidebar-nav-active" data-target="post-toc-wrap">
            Table of Contents
          </li>
          <li class="sidebar-nav-overview" data-target="site-overview-wrap">
            Overview
          </li>
        </ul>
      

      <section class="site-overview-wrap sidebar-panel">
        <div class="site-overview">
          <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
            
              <img class="site-author-image" itemprop="image" src="/images/arina.jpg" alt="Ming">
            
              <p class="site-author-name" itemprop="name">Ming</p>
              <p class="site-description motion-element" itemprop="description">Come on, check me out!</p>
          </div>

          <nav class="site-state motion-element">

            
              <div class="site-state-item site-state-posts">
              
                <a href="/archives/">
              
                  <span class="site-state-item-count">153</span>
                  <span class="site-state-item-name">posts</span>
                </a>
              </div>
            

            
              
              
              <div class="site-state-item site-state-categories">
                <a href="/categories/index.html">
                  <span class="site-state-item-count">16</span>
                  <span class="site-state-item-name">categories</span>
                </a>
              </div>
            

            

          </nav>

          

          
            <div class="links-of-author motion-element">
                
                  <span class="links-of-author-item">
                    <a href="https://github.com/carpediemtal" target="_blank" title="GitHub">
                      
                        <i class="fa fa-fw fa-github"></i>GitHub</a>
                  </span>
                
                  <span class="links-of-author-item">
                    <a href="mail:674602921@qq.com" target="_blank" title="E-Mail">
                      
                        <i class="fa fa-fw fa-envelope"></i>E-Mail</a>
                  </span>
                
                  <span class="links-of-author-item">
                    <a href="qq:674602921" target="_blank" title="QQ">
                      
                        <i class="fa fa-fw fa-qq"></i>QQ</a>
                  </span>
                
                  <span class="links-of-author-item">
                    <a href="overwatchID:SEKAI#51158" target="_blank" title="Overwatch">
                      
                        <i class="fa fa-fw fa-gamepad"></i>Overwatch</a>
                  </span>
                
            </div>
          

          
          

          
          
            <div class="links-of-blogroll motion-element links-of-blogroll-block">
              <div class="links-of-blogroll-title">
                <i class="fa  fa-fw fa-link"></i>
                Links
              </div>
              <ul class="links-of-blogroll-list">
                
                  <li class="links-of-blogroll-item">
                    <a href="http://www.treasurew.com/" title="treasurew" target="_blank">treasurew</a>
                  </li>
                
              </ul>
            </div>
          

          

        </div>
      </section>

      
      <!--noindex-->
        <section class="post-toc-wrap motion-element sidebar-panel sidebar-panel-active">
          <div class="post-toc">

            
              
            

            
              <div class="post-toc-content"><ol class="nav"><li class="nav-item nav-level-1"><a class="nav-link" href="#走进java"><span class="nav-number">1.</span> <span class="nav-text">走进java</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#概述"><span class="nav-number">1.1.</span> <span class="nav-text">概述</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#优点"><span class="nav-number">1.1.1.</span> <span class="nav-text">优点</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#java技术体系"><span class="nav-number">1.2.</span> <span class="nav-text">java技术体系</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#组成"><span class="nav-number">1.2.1.</span> <span class="nav-text">组成</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-VS-JRE"><span class="nav-number">1.2.2.</span> <span class="nav-text">JDK VS JRE</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#java发展史"><span class="nav-number">1.3.</span> <span class="nav-text">java发展史</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#James-Gosling"><span class="nav-number">1.3.1.</span> <span class="nav-text">James Gosling</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#Oak"><span class="nav-number">1.3.2.</span> <span class="nav-text">Oak</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-0"><span class="nav-number">1.3.3.</span> <span class="nav-text">JDK 1.0</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-1"><span class="nav-number">1.3.4.</span> <span class="nav-text">JDK 1.1</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-1发布了9个版本"><span class="nav-number">1.3.5.</span> <span class="nav-text">JDK 1.1发布了9个版本</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-2"><span class="nav-number">1.3.6.</span> <span class="nav-text">JDK 1.2</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#HotSpot虚拟机发布"><span class="nav-number">1.3.7.</span> <span class="nav-text">HotSpot虚拟机发布</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-3"><span class="nav-number">1.3.8.</span> <span class="nav-text">JDK 1.3</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-4"><span class="nav-number">1.3.9.</span> <span class="nav-text">JDK 1.4</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#NET-Framework发布"><span class="nav-number">1.3.10.</span> <span class="nav-text">.NET Framework发布</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-5"><span class="nav-number">1.3.11.</span> <span class="nav-text">JDK 1.5</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#JDK-1-6"><span class="nav-number">1.3.12.</span> <span class="nav-text">JDK 1.6</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#Sun被Oracle收购"><span class="nav-number">1.3.13.</span> <span class="nav-text">Sun被Oracle收购</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#展望Java的未来"><span class="nav-number">1.4.</span> <span class="nav-text">展望Java的未来</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#模块化"><span class="nav-number">1.4.1.</span> <span class="nav-text">模块化</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#混合语言"><span class="nav-number">1.4.2.</span> <span class="nav-text">混合语言</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#多核并行"><span class="nav-number">1.4.3.</span> <span class="nav-text">多核并行</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#丰富语法"><span class="nav-number">1.4.4.</span> <span class="nav-text">丰富语法</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#64位虚拟机"><span class="nav-number">1.4.5.</span> <span class="nav-text">64位虚拟机</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#自己编译JDK"><span class="nav-number">1.5.</span> <span class="nav-text">自己编译JDK</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#获取JDK原码"><span class="nav-number">1.5.1.</span> <span class="nav-text">获取JDK原码</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#构建编译环境"><span class="nav-number">1.5.2.</span> <span class="nav-text">构建编译环境</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#OPEN-JDK也不是100-开源的，有些依赖项是闭包的，得手动下载那些个依赖项才好JDK-plug"><span class="nav-number">1.5.3.</span> <span class="nav-text">OPEN JDK也不是100%开源的，有些依赖项是闭包的，得手动下载那些个依赖项才好JDK plug</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#开始编译"><span class="nav-number">1.5.4.</span> <span class="nav-text">开始编译</span></a></li></ol></li></ol></li></ol></div>
            

          </div>
        </section>
      <!--/noindex-->
      

      

    </div>
  </aside>


        
      </div>
    </main>

    <footer id="footer" class="footer">
      <div class="footer-inner">
        <div class="copyright">&copy; 2019 &mdash; <span itemprop="copyrightYear">2020</span>
  <span class="with-love">
    <i class="fa fa-user"></i>
  </span>
  <span class="author" itemprop="copyrightHolder">Ming</span>

  
    <span class="post-meta-divider">|</span>
    <span class="post-meta-item-icon">
      <i class="fa fa-area-chart"></i>
    </span>
    
      <span class="post-meta-item-text">Site words total count&#58;</span>
    
    <span title="Site words total count">64.9k</span>
  
</div>


  <div class="powered-by">Powered by <a class="theme-link" target="_blank" href="https://hexo.io">Hexo</a></div>



  <span class="post-meta-divider">|</span>



  <div class="theme-info">Theme &mdash; <a class="theme-link" target="_blank" href="https://github.com/iissnan/hexo-theme-next">NexT.Gemini</a> v5.1.4</div>




        







        
      </div>
    </footer>

    
      <div class="back-to-top">
        <i class="fa fa-arrow-up"></i>
        
      </div>
    

    

  </div>

  

<script type="text/javascript">
  if (Object.prototype.toString.call(window.Promise) !== '[object Function]') {
    window.Promise = null;
  }
</script>









  


  











  
  
    <script type="text/javascript" src="/lib/jquery/index.js?v=2.1.3"></script>
  

  
  
    <script type="text/javascript" src="/lib/fastclick/lib/fastclick.min.js?v=1.0.6"></script>
  

  
  
    <script type="text/javascript" src="/lib/jquery_lazyload/jquery.lazyload.js?v=1.9.7"></script>
  

  
  
    <script type="text/javascript" src="/lib/velocity/velocity.min.js?v=1.2.1"></script>
  

  
  
    <script type="text/javascript" src="/lib/velocity/velocity.ui.min.js?v=1.2.1"></script>
  

  
  
    <script type="text/javascript" src="/lib/fancybox/source/jquery.fancybox.pack.js?v=2.1.5"></script>
  

  
  
    <script type="text/javascript" src="/lib/canvas-nest/canvas-nest.min.js"></script>
  


  


  <script type="text/javascript" src="/js/src/utils.js?v=5.1.4"></script>

  <script type="text/javascript" src="/js/src/motion.js?v=5.1.4"></script>



  
  


  <script type="text/javascript" src="/js/src/affix.js?v=5.1.4"></script>

  <script type="text/javascript" src="/js/src/schemes/pisces.js?v=5.1.4"></script>



  
  <script type="text/javascript" src="/js/src/scrollspy.js?v=5.1.4"></script>
<script type="text/javascript" src="/js/src/post-details.js?v=5.1.4"></script>



  


  <script type="text/javascript" src="/js/src/bootstrap.js?v=5.1.4"></script>



  


  




	





  





  












  

  <script type="text/javascript">
    // Popup Window;
    var isfetched = false;
    var isXml = true;
    // Search DB path;
    var search_path = "search.xml";
    if (search_path.length === 0) {
      search_path = "search.xml";
    } else if (/json$/i.test(search_path)) {
      isXml = false;
    }
    var path = "/" + search_path;
    // monitor main search box;

    var onPopupClose = function (e) {
      $('.popup').hide();
      $('#local-search-input').val('');
      $('.search-result-list').remove();
      $('#no-result').remove();
      $(".local-search-pop-overlay").remove();
      $('body').css('overflow', '');
    }

    function proceedsearch() {
      $("body")
        .append('<div class="search-popup-overlay local-search-pop-overlay"></div>')
        .css('overflow', 'hidden');
      $('.search-popup-overlay').click(onPopupClose);
      $('.popup').toggle();
      var $localSearchInput = $('#local-search-input');
      $localSearchInput.attr("autocapitalize", "none");
      $localSearchInput.attr("autocorrect", "off");
      $localSearchInput.focus();
    }

    // search function;
    var searchFunc = function(path, search_id, content_id) {
      'use strict';

      // start loading animation
      $("body")
        .append('<div class="search-popup-overlay local-search-pop-overlay">' +
          '<div id="search-loading-icon">' +
          '<i class="fa fa-spinner fa-pulse fa-5x fa-fw"></i>' +
          '</div>' +
          '</div>')
        .css('overflow', 'hidden');
      $("#search-loading-icon").css('margin', '20% auto 0 auto').css('text-align', 'center');

      $.ajax({
        url: path,
        dataType: isXml ? "xml" : "json",
        async: true,
        success: function(res) {
          // get the contents from search data
          isfetched = true;
          $('.popup').detach().appendTo('.header-inner');
          var datas = isXml ? $("entry", res).map(function() {
            return {
              title: $("title", this).text(),
              content: $("content",this).text(),
              url: $("url" , this).text()
            };
          }).get() : res;
          var input = document.getElementById(search_id);
          var resultContent = document.getElementById(content_id);
          var inputEventFunction = function() {
            var searchText = input.value.trim().toLowerCase();
            var keywords = searchText.split(/[\s\-]+/);
            if (keywords.length > 1) {
              keywords.push(searchText);
            }
            var resultItems = [];
            if (searchText.length > 0) {
              // perform local searching
              datas.forEach(function(data) {
                var isMatch = false;
                var hitCount = 0;
                var searchTextCount = 0;
                var title = data.title.trim();
                var titleInLowerCase = title.toLowerCase();
                var content = data.content.trim().replace(/<[^>]+>/g,"");
                var contentInLowerCase = content.toLowerCase();
                var articleUrl = decodeURIComponent(data.url);
                var indexOfTitle = [];
                var indexOfContent = [];
                // only match articles with not empty titles
                if(title != '') {
                  keywords.forEach(function(keyword) {
                    function getIndexByWord(word, text, caseSensitive) {
                      var wordLen = word.length;
                      if (wordLen === 0) {
                        return [];
                      }
                      var startPosition = 0, position = [], index = [];
                      if (!caseSensitive) {
                        text = text.toLowerCase();
                        word = word.toLowerCase();
                      }
                      while ((position = text.indexOf(word, startPosition)) > -1) {
                        index.push({position: position, word: word});
                        startPosition = position + wordLen;
                      }
                      return index;
                    }

                    indexOfTitle = indexOfTitle.concat(getIndexByWord(keyword, titleInLowerCase, false));
                    indexOfContent = indexOfContent.concat(getIndexByWord(keyword, contentInLowerCase, false));
                  });
                  if (indexOfTitle.length > 0 || indexOfContent.length > 0) {
                    isMatch = true;
                    hitCount = indexOfTitle.length + indexOfContent.length;
                  }
                }

                // show search results

                if (isMatch) {
                  // sort index by position of keyword

                  [indexOfTitle, indexOfContent].forEach(function (index) {
                    index.sort(function (itemLeft, itemRight) {
                      if (itemRight.position !== itemLeft.position) {
                        return itemRight.position - itemLeft.position;
                      } else {
                        return itemLeft.word.length - itemRight.word.length;
                      }
                    });
                  });

                  // merge hits into slices

                  function mergeIntoSlice(text, start, end, index) {
                    var item = index[index.length - 1];
                    var position = item.position;
                    var word = item.word;
                    var hits = [];
                    var searchTextCountInSlice = 0;
                    while (position + word.length <= end && index.length != 0) {
                      if (word === searchText) {
                        searchTextCountInSlice++;
                      }
                      hits.push({position: position, length: word.length});
                      var wordEnd = position + word.length;

                      // move to next position of hit

                      index.pop();
                      while (index.length != 0) {
                        item = index[index.length - 1];
                        position = item.position;
                        word = item.word;
                        if (wordEnd > position) {
                          index.pop();
                        } else {
                          break;
                        }
                      }
                    }
                    searchTextCount += searchTextCountInSlice;
                    return {
                      hits: hits,
                      start: start,
                      end: end,
                      searchTextCount: searchTextCountInSlice
                    };
                  }

                  var slicesOfTitle = [];
                  if (indexOfTitle.length != 0) {
                    slicesOfTitle.push(mergeIntoSlice(title, 0, title.length, indexOfTitle));
                  }

                  var slicesOfContent = [];
                  while (indexOfContent.length != 0) {
                    var item = indexOfContent[indexOfContent.length - 1];
                    var position = item.position;
                    var word = item.word;
                    // cut out 100 characters
                    var start = position - 20;
                    var end = position + 80;
                    if(start < 0){
                      start = 0;
                    }
                    if (end < position + word.length) {
                      end = position + word.length;
                    }
                    if(end > content.length){
                      end = content.length;
                    }
                    slicesOfContent.push(mergeIntoSlice(content, start, end, indexOfContent));
                  }

                  // sort slices in content by search text's count and hits' count

                  slicesOfContent.sort(function (sliceLeft, sliceRight) {
                    if (sliceLeft.searchTextCount !== sliceRight.searchTextCount) {
                      return sliceRight.searchTextCount - sliceLeft.searchTextCount;
                    } else if (sliceLeft.hits.length !== sliceRight.hits.length) {
                      return sliceRight.hits.length - sliceLeft.hits.length;
                    } else {
                      return sliceLeft.start - sliceRight.start;
                    }
                  });

                  // select top N slices in content

                  var upperBound = parseInt('1');
                  if (upperBound >= 0) {
                    slicesOfContent = slicesOfContent.slice(0, upperBound);
                  }

                  // highlight title and content

                  function highlightKeyword(text, slice) {
                    var result = '';
                    var prevEnd = slice.start;
                    slice.hits.forEach(function (hit) {
                      result += text.substring(prevEnd, hit.position);
                      var end = hit.position + hit.length;
                      result += '<b class="search-keyword">' + text.substring(hit.position, end) + '</b>';
                      prevEnd = end;
                    });
                    result += text.substring(prevEnd, slice.end);
                    return result;
                  }

                  var resultItem = '';

                  if (slicesOfTitle.length != 0) {
                    resultItem += "<li><a href='" + articleUrl + "' class='search-result-title'>" + highlightKeyword(title, slicesOfTitle[0]) + "</a>";
                  } else {
                    resultItem += "<li><a href='" + articleUrl + "' class='search-result-title'>" + title + "</a>";
                  }

                  slicesOfContent.forEach(function (slice) {
                    resultItem += "<a href='" + articleUrl + "'>" +
                      "<p class=\"search-result\">" + highlightKeyword(content, slice) +
                      "...</p>" + "</a>";
                  });

                  resultItem += "</li>";
                  resultItems.push({
                    item: resultItem,
                    searchTextCount: searchTextCount,
                    hitCount: hitCount,
                    id: resultItems.length
                  });
                }
              })
            };
            if (keywords.length === 1 && keywords[0] === "") {
              resultContent.innerHTML = '<div id="no-result"><i class="fa fa-search fa-5x" /></div>'
            } else if (resultItems.length === 0) {
              resultContent.innerHTML = '<div id="no-result"><i class="fa fa-frown-o fa-5x" /></div>'
            } else {
              resultItems.sort(function (resultLeft, resultRight) {
                if (resultLeft.searchTextCount !== resultRight.searchTextCount) {
                  return resultRight.searchTextCount - resultLeft.searchTextCount;
                } else if (resultLeft.hitCount !== resultRight.hitCount) {
                  return resultRight.hitCount - resultLeft.hitCount;
                } else {
                  return resultRight.id - resultLeft.id;
                }
              });
              var searchResultList = '<ul class=\"search-result-list\">';
              resultItems.forEach(function (result) {
                searchResultList += result.item;
              })
              searchResultList += "</ul>";
              resultContent.innerHTML = searchResultList;
            }
          }

          if ('auto' === 'auto') {
            input.addEventListener('input', inputEventFunction);
          } else {
            $('.search-icon').click(inputEventFunction);
            input.addEventListener('keypress', function (event) {
              if (event.keyCode === 13) {
                inputEventFunction();
              }
            });
          }

          // remove loading animation
          $(".local-search-pop-overlay").remove();
          $('body').css('overflow', '');

          proceedsearch();
        }
      });
    }

    // handle and trigger popup window;
    $('.popup-trigger').click(function(e) {
      e.stopPropagation();
      if (isfetched === false) {
        searchFunc(path, 'local-search-input', 'local-search-result');
      } else {
        proceedsearch();
      };
    });

    $('.popup-btn-close').click(onPopupClose);
    $('.popup').click(function(e){
      e.stopPropagation();
    });
    $(document).on('keyup', function (event) {
      var shouldDismissSearchPopup = event.which === 27 &&
        $('.search-popup').is(':visible');
      if (shouldDismissSearchPopup) {
        onPopupClose();
      }
    });
  </script>





  

  

  

  
  

  

  

  

</body>
</html>
